package com.cet.designpatterns.factory.simplefactory.pizzastore.order;

import com.cet.designpatterns.factory.simplefactory.pizzastore.pizza.PepperPizza;

import java.lang.reflect.InvocationTargetException;

/**
 * @program: algorithm
 * @description: 相当于一个客户端，发出订购
 * @author: 陈恩涛
 * @create: 2021-08-31 23:16
 **/
public class PizzaStore {
    public static void main(String[] args) throws NoSuchMethodException, InstantiationException, IllegalAccessException, InvocationTargetException {
//        new OrderPizza();
        //使用简单工厂模式
        // new OrderPizza(new SimplePizzaFactory());

        //静态工厂
        //new OrderPizza2();

        new OrderPizza3(PepperPizza.class,"胡椒披萨");
    }
}
